package com.samuel.test;

public class testDiv {

    public static void main(String[] args) {

        System.out.println(getDistanceFormat(111000));
        System.out.println(getDistanceFormat(111100));
    }

    public static String getDistanceFormat(double distance){
        if(distance < 1000){
            return distance + "m";
        }else{

            return  Arithmetic.div(distance,1000.0,1)+ "km";
        }
    }



}
